{% block link_for_script %}
<!--<script src="//cdn.ckeditor.com/4.4.7/standard/ckeditor.js"></script>
<script>
    CKEDITOR.replace('editor');
</script>-->
<script src="{{ url_for('static', filename='tinymce/js/tinymce/tinymce.min.js') }}"></script>
<script src="{{ url_for('static', filename='js/tinymce_setup.js') }}"></script>
{% endblock %}

{% block link_for_script %}
<script src="{{ url_for('static', filename='ckeditor/ckeditor.js', _external=True)}}"></script>
<script>
    CKEDITOR.replace('editor');
</script>
{% endblock %}

<div class="">
        {{ form.name.label }} {% if form.name.errors %} {% for e in form.name.errors %}
        <p class="help-block">{{ e }}</p>
        {% endfor %} {% endif %} {{form.name(class_="form-control")}}
    </div>


    
    <div class="menu-bar-12" style="display:none;">
        <p class="text-center">我是萌萌嗒头头～～</p>
        <ul>
            <li>1</li>
            <li>2</li>
            <li>3</li>
            <li>4</li>
            <li>4</li>
        </ul>
    </div>
    <div class="col-sm-12">
        <div class="side-bar" style="display:none; overflow:hidden;">
            <div class="row">
                <h5 class="text-center">最近文章</h5>
                <ul>
                    <!--Recent posts-->
                    {% for post in recent %}
                    <span class="label label-info" style="display:inline-block;">
                            <!--Link for recent post-->
                            <a href="{{ url_for('blog.post', post_id=post.id) }}">
                                        {{ post.title }}
                                    </a>
                        </span>
                    <br /> {% endfor %}
                </ul>
            </div>
            <div class="row">
                <h5 class="text-center">最近标签</h5>
                <ul>
                    <!--Top five tags.-->
                    {% for tag in top_tags %}
                    <span class="label label-warning" style="display: inline-block;">
                            <!--link for tags.-->
                            <a href="{{ url_for('blog.tag', tag_name=tag[0].name) }}">
                                        {{tag[0].name}}
                                    </a>
                        </span>
                    <br /> {% endfor %}
                </ul>
            </div>
        </div>
    </div>


    <div class="btn btn-default" style="margin-left:10px;margin-bottom:12px;">
            <a href="{{ url_for('blog.post', post_id=post.id) }}">Read More...</a>
        </div>
